﻿using Daphne.Modularity.UI;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Windows.UI.Xaml.Controls;

namespace Daphne.Modularity.Storage
{
    /// <summary>
    /// Storage service class interface
    /// </summary>
    public interface IStorageService
    {
        /// <summary>
        /// Method for loading global settings
        /// </summary>
        void LoadConfig();

        /// <summary>
        /// Method for saving global settings
        /// </summary>
        void SaveConfig();

        /// <summary>
        /// Registering client requiring save / restore service
        /// </summary>
        void Register(ISaveRestore client);
       
        /// <summary>
        /// Saves the page's state
        /// </summary>
        void SetPageState(string key, PageState pageState, ClientStorage viewModelState);

        /// <summary>
        /// Returns the pages state
        /// </summary>
        void GetPageState(string key, out PageState pageState, out ClientStorage viewModelState);
    }
}
